package com.itcast.excel.hanlder;

import com.xxl.job.core.biz.model.ReturnT;
import com.xxl.job.core.handler.annotation.XxlJob;
import com.xxl.job.core.log.XxlJobLogger;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

/**
 * 任务调度Demo
 * 
 * @author zheng.zhang
 */
@Slf4j
@Component
public class DemoHandler {

    @XxlJob("reportDemo")
    public ReturnT<String> execute(String params) {
        XxlJobLogger.log("任务开始执行!参数为:{}", params);
        log.error("HA测试啦啦");
        XxlJobLogger.log("任务执行结束");
        return ReturnT.SUCCESS;
    }
}
